<template>
  <div id="app">
    <router-view />
    <Playbar v-show="$route.path !== 'songdetaill'" :class="$route.path == '/Recommend' ? 'bottom0' : 'bottom50'" />
  </div>
</template>
<script>
// export default {
//   name: 'App',
//   created() {
//     //在页面加载时读取sessionStorage里的状态信息
//     if (sessionStorage.getItem('store')) {
//       console.log(13213113132132)
//       this.$store.replaceState(Object.assign({}, this.$store.state, sessionStorage.getItem('store')))
//     }

//     //在页面刷新时将vuex里的信息保存到sessionStorage里
//     window.addEventListener('beforeunload', () => {
//       sessionStorage.setItem('store', this.$store.state)
//     })
//   },
// }
//
import Playbar from './components/comm/Playbar.vue'
export default {
  components: {
    Playbar,
  },
}
</script>

<style scoped>
.bottom50 {
  position: fixed;
  width: 100%;
  bottom: 50px;
  z-index: 99;
}
.bottom0 {
  position: fixed;
  width: 100%;
  bottom: 0px;
  z-index: 99;
}
</style>
